<template>
  <div class="goodList">
    <div
      @click="$router.push({ path: '/pages/shop/GoodsCon/index',query:{id:item.id} })"
      class="item acea-row row-between-wrapper"
      v-for="(item, goodlistIndex) in goodList"
      :key="goodlistIndex"
    >
      <div class="pictrue">
        <img :src="item.image" class="image" />
        <img :src="$VUE_APP_RESOURCES_URL+'/images/one.png'" class="numPic" v-if="isSort === true && index === 0" />
        <img :src="$VUE_APP_RESOURCES_URL+'/images/two.png'" class="numPic" v-if="isSort === true && index === 1" />
        <img :src="$VUE_APP_RESOURCES_URL+'/images/three.png'" class="numPic" v-if="isSort === true && index === 2" />
      </div>
      <div class="underline">
        <div class="text">
          <div class="line3">{{ item.storeName }}</div>
          <div class="money" style="color: #ff563d!important;font-size:36rpx">
            ￥
            <span class="num">{{ item.price }}</span>
          </div>
          <div class="vip-money acea-row row-middle">
            <div class="vip">
              ￥{{ item.otPrice || 0
              }}
            </div>
            <span class="num">已售{{ item.sales }}{{ item.unitName }}</span>
            <div style="position: absolute;right: 20rpx">
              <image 
                src="http://zykj-sales.oss-cn-hangzhou.aliyuncs.com/miniprogram/index-design/buy.png" 
                style="width: 50rpx;height: 50rpx;"
              />
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>
<script>
export default {
  name: "GoodList",
  props: {
    goodList: {
      type: Array,
      default: () => []
    },
    isSort: {
      type: Boolean,
      default: true
    }
  },
  data: function() {
    return {};
  }
};
</script>
